import request from '@/utils/request'
// 查询所有产品
export function listAllRoomInfo() {
  return request({
    url: '/roomInfo/listAllRoomInfo',
    method: 'get'
  })
}

// 分页查询
export function listRoomInfoByPage(data) {
  return request({
    url: '/roomInfo/page',
    method: 'get',
    params: data
  })
}

// 删除产品
export function delRoomInfo(infoId) {
  return request({
    url: '/roomInfo/' + infoId,
    method: 'delete'
  })
}

// 查询产品详细
export function getRoomInfo(infoId) {
  return request({
    url: '/roomInfo/' + infoId,
    method: 'get'
  })
}

// 新增产品
export function addRoomInfo(data) {
  return request({
    url: '/roomInfo',
    method: 'post',
    data: data
  })
}

// 修改产品
export function updateRoomInfo(data) {
  return request({
    url: '/roomInfo',
    method: 'put',
    data: data
  })
}

// 修改房间状态
// 修改房间状态
export function changeRoomStatus(data) {
  return request({
    url: '/roomInfo/changeStatus',
    method: 'get',
    params: data
  })
}

